<template>
	<view class="page">
		<!-- 头部 -->
		<!-- #ifdef MP-WEIXIN -->
			<topVue>
				<image 
					src="../../static/back.png" 
					style="width: 38rpx; height: 38rpx; left: 30rpx;" 
					class="absolute-middle"
					@click="$tools.back(1)"
				></image>
				<view class="absolute-auto flex align-center">
					<text class="fw600 fs32">发布活动</text>
					<image 
						src="../../static/index/question.png" 
						style="width: 34rpx; height: 34rpx; 
						margin-left: 15rpx;"
						@click="$tools.route('../site/explain')"
					></image>
				</view>
			</topVue>
		<!-- #endif -->
		<view class="item flex-between align-center margin0">
			<view class="fw600">活动名称：</view>
			<input type="text" placeholder="请输入活动名称" v-model="name"/>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">活动介绍：</view>
			<input type="text" placeholder="请输入活动名称" v-model="describetion"/>
		</view>
		<view class="item margin0 itemVue">
			<view class="fw600">活动封面：</view>
			<view class="uploadVue"></view>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">场地：</view>
			<view class="flex align-center">
				<view class="flex align-center" @click="current=0">
					<image src="../../static/index/selected.png" style="width: 28rpx; height: 28rpx; margin-right: 15rpx;" v-if="current===0"></image>
					<image src="../../static/index/select.png" style="width: 28rpx; height: 28rpx; margin-right: 15rpx;" v-if="current===1"></image>
					<text>合作场地</text>
				</view>
				<view style="width: 50rpx;"></view>
				<view class="flex align-center" @click="current=1">
					<image src="../../static/index/selected.png" style="width: 28rpx; height: 28rpx; margin-right: 15rpx;" v-if="current===1"></image>
					<image src="../../static/index/select.png" style="width: 28rpx; height: 28rpx; margin-right: 15rpx;" v-if="current===0"></image>
					<text>自主联系</text>
				</view>
			</view>
		</view>
		<view class="item flex-between align-center margin0" v-if="current===0">
			<view class="fw600">选择合作场地：</view>
			<view class="flex align-center">
				<input type="text" placeholder="请选择合作场地" v-model="site" disabled/>
				<image src="../../static/more.png" style="width: 38rpx; height: 38rpx;"></image>
			</view>
		</view>
		<view class="item flex-between align-center margin0" v-if="current===1">
			<view class="fw600">场地名称：</view>
			<input type="text" placeholder="请填写场地名称" v-model="siteName"/>
		</view>
		<view class="item flex-between align-center margin0" v-if="current===1">
			<view class="fw600">场地地址：</view>
			<input type="text" placeholder="请填写场地地址" v-model="siteAddress"/>
		</view>
		<view class="item flex-between align-center margin0" v-if="current===1">
			<view class="fw600">负责人电话：</view>
			<input type="text" placeholder="请填写负责人电话" v-model="sitePhone"/>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">报名费用：</view>
			<input type="text" placeholder="请设置报名费用" v-model="money"/>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">活动人数上限：</view>
			<input type="text" placeholder="请设置活动人数上限" v-model="numLimit"/>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">报名截止时间：</view>
			<view class="flex align-center">
				<input type="text" placeholder="请设置报名截止时间" v-model="applyLimit" disabled/>
				<image src="../../static/more.png" style="width: 38rpx; height: 38rpx;"></image>
			</view>
		</view>
		<view class="item flex-between align-center margin0">
			<view class="fw600">活动开始时间：</view>
			<view class="flex align-center">
				<input type="text" placeholder="请设置活动开始时间" v-model="start" disabled/>
				<image src="../../static/more.png" style="width: 38rpx; height: 38rpx;"></image>
			</view>
		</view>
		
		<view class="botVue flex-center align-center">
			<view class="apply fs30 fw600">提交活动申请</view>
		</view>
		
		<!-- 实名认证 -->
		<u-popup v-model="show" mode="center" >
			<view class="popVue relative">
				<image src="../../static/index/success.png" style="width: 218rpx; height: 258rpx; top: 0; z-index: 99;" class="absolute-center"></image>
				<view class="popupContent absolute">
					<view class="title fw600 fs36 text-center">实名认证</view>
					<view class="text-center margin40 fw600 padding-row30">
						当前账号未实名认证，是否前往认证？
					</view>
					<view class="btnVue flex-center margin80">
						<view class="toShow" @click="show=false; $tools.route('../person/certification/identity')">立即前往</view>
					</view>
				</view>
			</view>
		</u-popup>
	</view>
</template>

<script>
	export default {
		data(){
			return {
				name: "",
				describetion: "",
				current: 0,
				site: "",
				money: "",
				numLimit: "",
				applyLimit: "",
				start: "",
				siteName: "",
				siteAddress: "",
				sitePhone: "",
				show: true
			}
		}
	}
</script>

<style lang="less" scoped>
	.page {
		padding-bottom: 161rpx;
		/deep/.u-mode-center-box{
			background-color: transparent !important;
		}
	}
	.item {
		width: 690rpx;
		height: 108rpx;
		border-bottom: 1rpx solid #EEE;
		input {
			text-align: right;
			font-size: 28rpx;
		}
		.uploadVue {
			width: 140rpx;
			height: 140rpx;
			background: url("../../static/index/upload.png") no-repeat;
			background-size: 100% 100%;
			margin-top: 25rpx;
		}
	}
	.itemVue {
		width: 690rpx;
		height: auto;
		padding: 30rpx 0;
	}
	.botVue {
		width: 100%;
		height: 160rpx;
		background: #fff;
		position: fixed;
		left: 0;
		bottom: 0;
		padding: 0 30rpx;
		background: #FFFFFF;
		z-index: 999;
		.apply {
			width: 640rpx;
			height: 96rpx;
			background: #FC132F;
			border-radius: 48rpx;
			text-align: center;
			line-height: 96rpx;
			color: #FFFFFF;
		}
	}
	.popVue {
		width: 600rpx;
		height: 600rpx;
		.popupContent {
			width: 600rpx;
			height: 500rpx;
			background: linear-gradient(180deg, #F0E9F8, #F0E9F8, #FDE5E7, #FBEFF1, #FDFAFC, #fff);;
			left: 0;
			bottom: 0;
			border-radius: 40rpx;
			.title {
				color: #333;
				padding-top: 178rpx;
			}
			.toShow {
				width: 500rpx;
				height: 84rpx;
				line-height: 84rpx;
				text-align: center;
				border-radius: 42rpx;
				background: #FC132F;
				border-radius: 42rpx;
				color: #fff;
				font-weight: 600;
			}
		}
	}
</style>